1. Field of the Invention
The present invention relates to a method and apparatus for encoding and/or decoding image data, and more particularly, to an image encoding and/or decoding method and apparatus for performing temporal prediction encoding by correcting the pixel values of a previous image in order to increase encoding efficiency.
2. Description of Related Art
When an image is taken by a camera, the image generally has an RGB (red, green, blue) color space. This RGB image is used after converting the color space to fit each application field. As a color space that has been generally widely used in the video compression field, there is a YCbCr color space. Here, Y indicates a luma component and Cb and Cr indicate chroma components. However, since there is a limit to expression of a high picture quality in the YCbCr, an RGB color space or an XYZ color space is used in order to express a high picture quality.
Meanwhile, when moving pictures are compressed, temporal prediction encoding is performed, in which a current image is subtracted from a previous image and the result is encoded. At this time, the compression efficiency can be increased by performing prediction encoding more accurately with values obtained by modifying pixel values of the previous image by using a predetermined weight value. Here, the method of modifying the pixel values of the previous image is referred to as pixel value correction.
In the conventional image compression, when a series of images continuous with respect to time are encoded, the images are compressed through temporal prediction in order to remove redundant information between the previous image and the current image. In the Society of Motion Picture and Television Engineers (SMPTE) Standard for Television: VC-1 Compressed Video Bitstream Format and Decoding Process (VC-1) that has been undergoing standardization recently, a variety of temporal prediction methods are provided. Among the methods, there is a pixel value correction method in which the value of a previous image is multiplied by or added to a predetermined value and then by using the resultant value, a current image is encoded. By using this method, the efficiency of the temporal prediction method can be increased to enhance the compression ratio.
However, in the pixel value correction method used in the VC-1, the YCbCr color space is used as a fixed one. Though the YCbCr has been generally widely used for video encoding, the YCbCr has a limit to picture quality that can be expressed. When gradually increasing demands for high picture quality images are considered, a pixel value correction method adaptive to a color space is required so that an identical method can be used to an image using a color space other than the YCbCr color space.